{extend name="template/base_default"}
{block name="header"}
<link rel="stylesheet" href="__CSS__/common.css">
<link rel="stylesheet" href="__CDN__/weui/weui.min.css">
<link rel="stylesheet" href="__CSS__/login/index.css">
<link rel="stylesheet" href="__CSS__/weuix.min.css"/>
<script src="__JS__/zepto.min.js"></script>
<script src="__JS__/lrz.min.js"></script>
<style>

    .form-head{
        color: white;
        font-size: 16px;
        background-color: rgba(255, 255, 255, 0.2);
        border-radius: 5px;
        overflow: hidden;
    }
    body{
        background-image:url("__IMG__/bj.png");
        background-repeat:no-repeat;
        background-size:cover;
        text-align: center;
    }
</style>
{/block}
{block name="body"}

<form action="{:url('login/register')}" method="post" style="width:95%;margin: auto">
<div class="form-head">
    <div class="form-input3" >
        <label for="name" class="form-input3-label">车主姓名:</label>
        <input class="form-input3-input" id="name" name="name" type="text" value="" placeholder=" ">
    </div>
    <div class="form-input3">
        <label for="sex" class="form-input3-label">车牌号码:</label>
            <input class="form-input3-input" name="sex" id="sex" type="text" value="">
    </div>
    <div class="form-input3">
        <label for="name" class="form-input3-label">手机号码:</label>
        <input class="form-input3-input" id="content" name="content" type="text" value="" placeholder="">
    </div>


</div>
    <div class="form-body">

        <div class="idphoto-box headimgurl2" >
            <input class="weui_uploader_input headimgurl" type="file" accept="image/jpg,image/jpeg,image/png,image/gif"   />
            <input  type="hidden"   value="11" />
        </div>
        <div class="idphoto-box headimgurl2" style="background-image: url('__IMG__/sfzz.png')">
            <input class="weui_uploader_input headimgurl" type="file" accept="image/jpg,image/jpeg,image/png,image/gif"   />
            <input  type="hidden"  value="11" />
        </div>
        <div class="idphoto-box headimgurl2" >
            <input class="weui_uploader_input headimgurl" type="file" accept="image/jpg,image/jpeg,image/png,image/gif"  />
            <input  type="hidden"   value="11" />
        </div>
        <div class="idphoto-box headimgurl2" >
            <input class="weui_uploader_input headimgurl" type="file" accept="image/jpg,image/jpeg,image/png,image/gif"  />
            <input  type="hidden"   value="11" />
        </div>
        <div class="idphoto-box headimgurl2" >
            <input class="weui_uploader_input headimgurl" type="file" accept="image/jpg,image/jpeg,image/png,image/gif"  />
            <input  type="hidden"   value="11" />
        </div>
        <div class="tips-box ">
            <p style="color:#F5E20A">温馨提示：</p>
            <p style="color:#aaaaaa">
                所有照片横向拍摄避免阴影和反光
            </p>
        </div>
    </div>
    <div class="form-input">
        <button id="submit" class="login-btn2" type="button">提交</button>
    </div>
</form>
{/block}
{block name="footer"}
<script type="text/javascript" src="__JS__/public.js"></script>
<script>
    $(function(){


      //  var f = document.querySelector('#headimgurl');
        $('.headimgurl').change(function () {
            var formdata = new FormData();
            var v_this = $(this);
            var fileObj = v_this.get(0).files;
            url = "weixin.php/weixin/user/up1";
            formdata.append("file", fileObj[0]);
            jQuery.ajax({
                url : url,
                type : 'post',
                data : formdata,
                cache : false,
                contentType : false,
                processData : false,
                dataType : "json",
                success : function(data) {
                    if (data.error == 0) {
                        v_this.next().val(data.src);
                        v_this.parent().css("background-image","url("+data.src+")");
                    }
                }
            });
            return false;
        });
    })

</script>
{/block}